// JavaScript Document
function buttonOver(elmnt)
{
	elmnt.style.backgroundColor="#333333";
	elmnt.style.color="#ffffff";
}
function buttonOut(elmnt)
{
	elmnt.style.backgroundColor="transparent";
	elmnt.style.color="#9d9d9d";
}
function buttonClick(elmnt)
{
	window.location = elmnt;
}
function dropDown(id)
{
	document.getElementById(id).style.visibility="visible";
}
function dropUp(id)
{
	document.getElementById(id).style.visibility="hidden";
}
function changeActive(elmnt)
{
	if(document.getElementById(elmnt).style.visibility=="visible")
	{
		document.getElementById(elmnt).style.visibility="hidden";
		document.getElementById(elmnt).style.display="none";
	}
	else
	{
		document.getElementById(elmnt).style.visibility="visible";
		document.getElementById(elmnt).style.display="inline";
	}
}
function linkOver(elmnt)
{
	elmnt.style.color="#0019a0";
	elmnt.style.textDecoration="underline";
}
function linkOut(elmnt)
{
	elmnt.style.color="#4957a5";
	elmnt.style.textDecoration="none";
}
function disp_confirm_delete_resource()
{
	return confirm("Are you sure you would like to delete this resource?\r\nWarning: You will not be able to undo this action.");
}
function disp_confirm_delete_message()
{
	return confirm("Are you sure you would like to delete this message?\r\nWarning: You will not be able to undo this action.");
}
function disp_confirm_delete_user()
{
	return confirm("Are you sure you would like to delete this user?\r\nWarning: You will not be able to undo this action.");
}
function disp_confirm_delete_member()
{
	return confirm("Are you sure you would like to delete this member from your project?\r\nWarning: You will not be able to undo this action.");
}
function disp_confirm_delete_category()
{
	return confirm("Are you sure you would like to delete this category?\r\nWarning: You will not be able to undo this action.");
}
function disp_confirm_delete_needed_resource()
{
	return confirm("Are you sure you would like to delete this needed resource?\r\nWarning: You will not be able to undo this action.");
}
function disp_confirm_delete_project()
{
	return confirm("Are you sure you would like to delete this project?\r\nWarning: You will not be able to undo this action.");
}
function disp_confirm_delete_link()
{
	return confirm("Are you sure you would like to delete this link?\r\nWarning: You will not be able to undo this action.");
}
maxL=255;
var bName = navigator.appName;
function taLimit(taObj)
{
	if (taObj.value.length==maxL) return false;
	return true;
}
function taCount(taObj,Cnt)
{ 
	objCnt=createObject(Cnt);
	objVal=taObj.value;
	if(objVal.length>maxL) objVal=objVal.substring(0,maxL);
		if(objCnt)
		{
			if(bName == "Netscape")
			{	
				objCnt.textContent=maxL-objVal.length;
			}
			else
			{
				objCnt.innerText=maxL-objVal.length;
			}
		}
	return true;
}
function createObject(objId)
{
	if (document.getElementById) return document.getElementById(objId);
	else if (document.layers) return eval("document." + objId);
	else if (document.all) return eval("document.all." + objId);
	else return eval("document." + objId);
}
